---
title: Label
description: Renders an accessible label associated with controls.
---

<ComponentPreview name="p-input-6" />

## Installation

<CodeTabs>

<TabsList>
  <TabsTab value="cli">CLI</TabsTab>
  <TabsTab value="manual">Manual</TabsTab>
</TabsList>
<TabsPanel value="cli">

```bash
npx shadcn@latest add @coss/label
```

</TabsPanel>

<TabsPanel value="manual">

<Steps>

<Step>Copy and paste the following code into your project.</Step>

<ComponentSource name="label" title="components/ui/label.tsx" />

<Step>Update the import paths to match your project setup.</Step>

</Steps>

</TabsPanel>

</CodeTabs>

## Usage

```tsx
import { Label } from "@/components/ui/label"
```

```tsx
<Label htmlFor="email">Email</Label>
```

## Examples

For accessible labelling and validation, prefer using the `FieldLabel` component. See some [related examples](/ui/docs/components/field).

### With Checkbox

<ComponentPreview name="checkbox-demo" />
